import websocket
from websocket import create_connection


def sendmsg(msg):
    ws = create_connection("ws://127.0.0.1:12345")
    ws.send(msg)
    result = ws.recv()
    ws.close()
